From: Florian Müllner Date: Thu, 8 Jul 2021 21:42:49 +0000 (+0200) Subject: st/scroll-bar: Fix vertical scrollbars in RTL locales X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~574^2^2~224 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=0e72579364059ba5ee829cdd1d594009f725f991;p=gnome-shell.git st/scroll-bar: Fix vertical scrollbars in RTL locales Commit 0db41a3773e fixed the handling of horizontal scrollbars in RTL locales, but accidentally applied the translation to *all* scrollbars when handling handle drags and paging. Fix this by limiting the mirroring to horizontal bars. https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4458 Part-of: --- diff --git a/src/st/st-scroll-bar.c b/src/st/st-scroll-bar.c index 59e9ca820..01674df65 100644 --- a/src/st/st-scroll-bar.c +++ b/src/st/st-scroll-bar.c @@ -633,7 +633,7 @@ move_slider (StScrollBar *bar, &page_size); direction = clutter_actor_get_text_direction (CLUTTER_ACTOR (bar)); - if (direction == CLUTTER_TEXT_DIRECTION_RTL) + if (!priv->vertical && direction == CLUTTER_TEXT_DIRECTION_RTL) pos = size - pos; position = ((pos / size) @@ -778,7 +778,7 @@ trough_paging_cb (StScrollBar *self) &tx, &ty); direction = clutter_actor_get_text_direction (CLUTTER_ACTOR (self)); - if (direction == CLUTTER_TEXT_DIRECTION_RTL) + if (!priv->vertical && direction == CLUTTER_TEXT_DIRECTION_RTL) page_increment *= -1; if (priv->vertical)